package com.visionblue.business.ship.model.api

import retrofit2.Retrofit
import retrofit2.converter.gson.GsonConverterFactory

/**
 * @author: xlh
 * @date: 2020-04-10 2:25 PM
 * @desc:
 */
object MRetrofit {

    private val mRetrofit = Retrofit.Builder()
        .baseUrl(Network.BASE_URL)
        .client(OkHttpClientProvider.client)
        .addConverterFactory(GsonConverterFactory.create())
        .build()

    fun <T> create(service: Class<T>): T {
        return mRetrofit.create(service)
    }
}